package 富婆梦.第一阶段.Java基础视频学习.线程的练习.练习;

import java.util.concurrent.Callable;

/**
 * @ProjectName: java-learning
 * @Package: 富婆梦.第一阶段.线程的练习.练习
 * @ClassName: CallableTest
 * @Author: hemengjin
 * @Description: 测试callable的功能
 * @Date:2021/10/18 19:12
 * @Version: 1.0
 */
public class CallableTest implements Callable<String> {
    private int id;

    public CallableTest(int id) {
        this.id = id;
    }

    @Override
    public String call() throws Exception {
        return "result of CallableTest"+id;
    }

}
